import os
from PyQt5.QtWidgets import QApplication, QWidget, QPushButton, QVBoxLayout, QTextEdit, QFileDialog, QMessageBox, QProgressBar
from PyQt5.QtCore import Qt
from PyQt5.QtGui import QIcon
from PIL import Image
import pytesseract

# 设置Tesseract-OCR的安装路径（适用于Windows）
pytesseract.pytesseract.tesseract_cmd = os.path.join(os.path.dirname(__file__), 'tesseract', 'tesseract.exe')

from OcrApp import OcrApp

if __name__ == '__main__':
    import sys
    app = QApplication(sys.argv)

    window = OcrApp()
    window.show()

    sys.exit(app.exec_())
